<template>
    <div>
        <Modal v-model="modal.search" title="高级搜索" width="1020">
            <Form ref="searchForm" :model="searchForm" :label-width="120">
                <Row>
	<i-col span="12">
	<FormItem label="用户编号"><Row>
	<i-col span="11">
	<FormItem prop="userIdMin">
	<InputNumber v-model="searchForm.userIdMin" placeholder="请输入开始用户编号" style="width: 100%;"/>
</FormItem>
</i-col>
	<i-col span="2" style="text-align: center">-</i-col>
	<i-col span="11">
	<FormItem prop="userIdMax">
	<InputNumber v-model="searchForm.userIdMax" placeholder="请输入结束用户编号" style="width: 100%;"/>
</FormItem>
</i-col>
</Row>
</FormItem>
</i-col><i-col span="12">
	<FormItem label="手机号" prop="userPhone">
	<Input v-model="searchForm.userPhone" placeholder="请输入手机号" clearable/>
</FormItem>
</i-col>

	<i-col span="12">
	<FormItem label="用户邮箱" prop="userEmail">
	<Input v-model="searchForm.userEmail" placeholder="请输入用户邮箱" clearable/>
</FormItem>
</i-col><i-col span="12">
	<FormItem label="昵称" prop="userDetailNickname">
	<Input v-model="searchForm.userDetailNickname" placeholder="请输入昵称" clearable/>
</FormItem>
</i-col>

	<i-col span="12">
	<FormItem label="头像地址" prop="userDetailHeadicon">
	<Input v-model="searchForm.userDetailHeadicon" placeholder="请输入头像地址" clearable/>
</FormItem>
</i-col><i-col span="12">
	<FormItem label="消息编号"><Row>
	<i-col span="11">
	<FormItem prop="messageIdMin">
	<InputNumber v-model="searchForm.messageIdMin" placeholder="请输入开始消息编号" style="width: 100%;"/>
</FormItem>
</i-col>
	<i-col span="2" style="text-align: center">-</i-col>
	<i-col span="11">
	<FormItem prop="messageIdMax">
	<InputNumber v-model="searchForm.messageIdMax" placeholder="请输入结束消息编号" style="width: 100%;"/>
</FormItem>
</i-col>
</Row>
</FormItem>
</i-col>

	<i-col span="12">
	<FormItem label="消息标题" prop="messageTitle">
	<Input v-model="searchForm.messageTitle" placeholder="请输入消息标题" clearable/>
</FormItem>
</i-col><i-col span="12">
	<FormItem label="封面图片" prop="messageCoverImg">
	<Input v-model="searchForm.messageCoverImg" placeholder="请输入封面图片" clearable/>
</FormItem>
</i-col>

	<i-col span="12">
	<FormItem label="消息摘要" prop="messageSummary">
	<Input v-model="searchForm.messageSummary" placeholder="请输入消息摘要" clearable/>
</FormItem>
</i-col><i-col span="12">
	<FormItem label="消息内容" prop="messageContent">
	<Input v-model="searchForm.messageContent" placeholder="请输入消息内容" clearable/>
</FormItem>
</i-col>

	<i-col span="12">
	<FormItem label="消息类型" prop="messageMessageType">
	<Input v-model="searchForm.messageMessageType" placeholder="请输入消息类型" clearable/>
</FormItem>
</i-col><i-col span="12">
	<FormItem label="关联页面链接" prop="messageLinkPageUrl">
	<Input v-model="searchForm.messageLinkPageUrl" placeholder="请输入关联页面链接" clearable/>
</FormItem>
</i-col>

	<i-col span="12">
		<FormItem label="关联页面参数" prop="messageLinkParams">
	<Input v-model="searchForm.messageLinkParams" placeholder="请输入关联页面参数" clearable/>
</FormItem>
</i-col><i-col span="12">
	<FormItem label="是否已读"><Row>
	<i-col span="11">
	<FormItem prop="userMessageIsReadMin">
	<InputNumber v-model="searchForm.userMessageIsReadMin" placeholder="请输入开始是否已读" style="width: 100%;"/>
</FormItem>
</i-col>
	<i-col span="2" style="text-align: center">-</i-col>
	<i-col span="11">
	<FormItem prop="userMessageIsReadMax">
	<InputNumber v-model="searchForm.userMessageIsReadMax" placeholder="请输入结束是否已读" style="width: 100%;"/>
</FormItem>
</i-col>
</Row>
</FormItem>
</i-col>

	<i-col span="12">
	<FormItem label="版本号"><Row>
	<i-col span="11">
	<FormItem prop="userMessageVersionMin">
	<InputNumber v-model="searchForm.userMessageVersionMin" placeholder="请输入开始版本号" style="width: 100%;"/>
</FormItem>
</i-col>
	<i-col span="2" style="text-align: center">-</i-col>
	<i-col span="11">
	<FormItem prop="userMessageVersionMax">
	<InputNumber v-model="searchForm.userMessageVersionMax" placeholder="请输入结束版本号" style="width: 100%;"/>
</FormItem>
</i-col>
</Row>
</FormItem>
</i-col><i-col span="12">
	<FormItem label="创建时间"><Row>
	<i-col span="11">
	<FormItem prop="userMessageCreateTimeMin">
	<DatePicker @on-change="searchForm.userMessageCreateTimeMin=$event" :value="searchForm.userMessageCreateTimeMin" placeholder="请输入开始创建时间" type="datetime" format="yyyy-MM-dd HH:mm:ss" style="width: 100%;" clearable></DatePicker>
</FormItem>
</i-col>
	<i-col span="2" style="text-align: center">-</i-col>
	<i-col span="11">
	<FormItem prop="userMessageCreateTimeMax">
	<DatePicker @on-change="searchForm.userMessageCreateTimeMax=$event" :value="searchForm.userMessageCreateTimeMax" placeholder="请输入结束创建时间" type="datetime" format="yyyy-MM-dd HH:mm:ss" style="width: 100%;" clearable></DatePicker>
</FormItem>
</i-col>
</Row>
</FormItem>
</i-col>

	<i-col span="12">
	<FormItem label="更新时间"><Row>
	<i-col span="11">
	<FormItem prop="userMessageUpdateTimeMin">
	<DatePicker @on-change="searchForm.userMessageUpdateTimeMin=$event" :value="searchForm.userMessageUpdateTimeMin" placeholder="请输入开始更新时间" type="datetime" format="yyyy-MM-dd HH:mm:ss" style="width: 100%;" clearable></DatePicker>
</FormItem>
</i-col>
	<i-col span="2" style="text-align: center">-</i-col>
	<i-col span="11">
	<FormItem prop="userMessageUpdateTimeMax">
	<DatePicker @on-change="searchForm.userMessageUpdateTimeMax=$event" :value="searchForm.userMessageUpdateTimeMax" placeholder="请输入结束更新时间" type="datetime" format="yyyy-MM-dd HH:mm:ss" style="width: 100%;" clearable></DatePicker>
</FormItem>
</i-col>
</Row>
</FormItem>
</i-col><i-col span="12">
	<FormItem label="是否激活" prop="userMessageIsActive">
	    
	        <Select v-model="searchForm.userMessageIsActive" placeholder="是否激活" filterable clearable>
	          <Option
	            v-for="(option, index) in isActiveSelect"
	            :value="option.value"
	            :key="index"
	          >{{option.displayValue}}</Option>
	        </Select>
	    
	</FormItem>
	
</i-col>
</Row>

            </Form>
            <div slot="footer">
                <Button type="text" size="large" @click="resetForm">清空</Button>
                <Button type="text" size="large" @click="cancelModal">取消</Button>
                <Button type="primary" size="large" @click="searchOkModal" :loading="loading.search">查询</Button>
            </div>
        </Modal>
    </div>
</template>

<script>
	import * as utils from '@/api/utils-v2'
	import * as ResponseStatus from '@/api/response-status'
    export default {
        name: 'UserUserMessageSearch',
        data() {
            return {
                modal: {
                    search: false
                },
                loading: {
                    search: false
                },
				dataDictCodes: ['IS_ACTIVE'],
				dataDictItems: {},
				isActiveSelect:[],
                urls: {
                    searchUrl: '/user-usermessage/admin/pager-cond'
                },
                searchForm: {
                    pageNo: 1,
                    pageSize: 10,
                    sortColumn: null,
                    sortOrder: null,
                    userId: null,
userIdMin: null, 
userIdMax: null, 
userPhone: null,
userEmail: null,
userDetailNickname: null,
userDetailHeadicon: null,
messageId: null,
messageIdMin: null, 
messageIdMax: null, 
messageTitle: null,
messageCoverImg: null,
messageSummary: null,
messageContent: null,
messageMessageType: null,
messageLinkPageUrl: null,
messageLinkParams: null,
messageLinkParamsMin: null, 
messageLinkParamsMax: null, 
userMessageIsRead: null,
userMessageIsReadMin: null, 
userMessageIsReadMax: null, 
userMessageVersion: null,
userMessageVersionMin: null, 
userMessageVersionMax: null, 
userMessageCreateTime: null,
userMessageCreateTimeMin: null, 
userMessageCreateTimeMax: null, 
userMessageUpdateTime: null,
userMessageUpdateTimeMin: null, 
userMessageUpdateTimeMax: null, 
userMessageIsActive: null,
userMessageIsActiveMin: null, 
userMessageIsActiveMax: null, 

                }
            }
        },
        computed: {},
        mounted() {
			  utils.getDataDict(this.dataDictCodes).then(response => {
				  if (response) {
					this.dataDictItems = response
					utils.getSelectDictItems(this, 'IS_ACTIVE', 'userMessageIsActive', 'isActiveSelect')
				  }
				}).catch(error => {
				  console.log(error)
				})
		},
        methods: {
            resetForm() {
                this.$refs.searchForm.resetFields()
            },
            cancelModal(modal) {
                this.modal.search = false
            },
            searchOkModal(modal) {
                this.modal.search = false
                this.$emit('searchTable', true)
            }
        }
    }
</script>

<style>
</style>
